Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 11:31 25 Nov 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Electronics : Analog Meters On Piclog

     Page 2 of 2    
Author Message
oztules

Guru

Joined: 26/07/2007
Location: Australia
Posts: 1686
Posted: 10:51am 06 Jun 2010
Copy link to clipboard 
Print this post

It's all good development. I like to see this....... (but I still won't use windows )

I agree completely Pete



...........oztules
Village idiot...or... just another hack out of his depth
 
Gizmo

Admin Group

Joined: 05/06/2004
Location: Australia
Posts: 5078
Posted: 11:13am 06 Jun 2010
Copy link to clipboard 
Print this post

Good to see this update apears to fix that old bug. If its still working after a couple of days I'll update the PicLog article with this bug fix and a few other changes.

I've been on the lookout for a cross platform free alternative to VB6. While VB6 is easy to use and has a lot of grunt, its not free, and its no longer available unless you can source a 2nd hand copy. Visual Studio 2005 and 2008 have free versions, but its bloatware to the extreme and not as user friendly as VB6. A cross platform version of visual basic would be great, and I would love to rewrite the PicLog to work on other OS's. The PicLogs text file storage of data is simple and would port to other systems, but com port handling could be a challenge as Windows and Linux treat the com port very differently.

I'll keep looking for an VB6 alternative ( this is where Vasi will hopefully chime in with the answer )

Glenn
The best time to plant a tree was twenty years ago, the second best time is right now.
JAQ
 
windman1000
Regular Member

Joined: 21/06/2009
Location: United States
Posts: 91
Posted: 07:15pm 06 Jun 2010
Copy link to clipboard 
Print this post

Ok I Took Glenns Last Subs he posted and put them in the meter piclog and all works good here, so try this and let us know.( Recap) this needs to go in piclog folder and you need the orignal files/folders in that Piclog folder.
And the rpm and the windspeed Meters are posted all the time.
2010-06-07_051430_Meter3.zipEdited by windman1000 2010-06-08
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 01:59am 07 Jun 2010
Copy link to clipboard 
Print this post

Windman,

It worked!!!!!!

I did have a few dramas though, as the logger i tested it on was on 240 volt i calibrated it to 240 and it crashed with error 380 till i dropped the voltage value back. (it was off scale)

A few things i noticed is ... it dont show values on the meters unless you are recording...a draw back.

I notice you only have full figures shown for amps and wind etc, and i for one like to see to at least 1 decmial point. I dont care about volts, rpm and watts.

It still has the old problem of ..if you get the com port wrong it locks you out and you need to go into the prog file to change it.

It would be nice to have a high and low scale button on the amp and wind gauges as when there is low readings the needle is close to zero and hard to read.

Otherwise all worked and well done.

Pete.

Ps:- you might want to ask Glenn to edit the earlier Zip files so there is not to many versions posted, and nothing worst than versions that dont work.
Edited by Downwind 2010-06-08
Sometimes it just works
 
vasi

Guru

Joined: 23/03/2007
Location: Romania
Posts: 1697
Posted: 07:18am 07 Jun 2010
Copy link to clipboard 
Print this post

Hi guys,

Commercial alternatives

1. If there are possibilities, then I strongly recommend the PowerBasic (Windows and Dos) for his performances and the impressive list of customers (and, as a personal reason, because is the successor of Turbo Pascal from Borland). Read about it on his site.
Price: Good
- Site
- Customers

2. Second, I recommend PureBasic as cross platform solution (Win, Linux, Mac, Amiga), with a huge list of 1100+ internal commands and also great compiler results (very fast and compact code single executable - no bloatware, no additional dll's or runtime's).
- Site
- Screenshots
Price: Very good

Code example (Serial port on both systems, Win and Linux):
[code]
; ------------------------------------------------------------
;
; PureBasic - SerialPort example file
;
; (c) Fantaisie Software
;
; ------------------------------------------------------------
;

CompilerIf #PB_Compiler_OS = #PB_OS_Windows
Port$ = "COM1"
CompilerElse
Port$ = "/dev/ttyS0"
CompilerEndIf

If OpenSerialPort(0, Port$, 300, #PB_SerialPort_NoParity, 8, 1, #PB_SerialPort_NoHandshake, 1024, 1024)

MessageRequester("Information", "SerialPort opened with success")

Else
MessageRequester("Error", "Can't open the serial port: "+Port$)
EndIf
[/code]
Yes, this is the only difference regarding to Serial Comm. ports (the string which designate the serial comm port) between Linux and Windows and this is true also for other cross platforms languages (C++, Freepascal, etc.)

3. Another cross platform solution (Win, Mac, Linux) is RealBasic but with not so small resulted executable.
Price: Too expensive
- Site

There is also Liberty Basic but is only for Windows and I don't recommend it because compiled result is poor.

Freeware alternatives

A good cross platform solution (Win and Linux) is FreeBasic 32 bit compiler
- Site
- Gallery

To be continued...Edited by vasi 2010-06-08
Hobbit name: Togo Toadfoot of Frogmorton
Elvish name: Mablung Miriel
Beyound Arduino Lang
 
vasi

Guru

Joined: 23/03/2007
Location: Romania
Posts: 1697
Posted: 08:04am 07 Jun 2010
Copy link to clipboard 
Print this post

Considerations about Serial ports on cross platform:

On Linux
/dev/ttyS0 - when is about a physical serial comm. port
/dev/ttyACM0 - when is about USB-CDC Serial
/dev/ttyUSB0 - when is about other USB devices (modems e.g.).

You can see what comm port have been allocated to your device using dmesg console command (when you insert an USB device after the computer initialization or when you reset the board often if you are in development process).

An example. If you reset your device (logger) without closing your terminal console application, then on the next initialization, linux will allocate another virtual device: if it was /dev/ttyACM0, it will be /dev/ttyACM1. You must know this when you restart your PC application. If you reset your board after your PC application closed the serial comm., then at reinitialization, your board will have same device allocated: /dev/ttyACM0

Also, on Windows an USB device have bigger values than the physical serial ports COM1 - COM4 ...

So it is better to have a text input field rater than a combo box (with the required tooltip as help or a neighbor text label as indication for the format of the string [COM1, /dev/ttyS0, /dev/ttyACM0, etc.])... or better an editable combo box.

Vasi
Hobbit name: Togo Toadfoot of Frogmorton
Elvish name: Mablung Miriel
Beyound Arduino Lang
 
windman1000
Regular Member

Joined: 21/06/2009
Location: United States
Posts: 91
Posted: 09:43pm 07 Jun 2010
Copy link to clipboard 
Print this post

I Was Looking over Glenns Version 3 Piclogger And Noticed That My MeterLogger Had Old And New Sub Codes So I Redid Everything To Glenns Version 3 And Even Thow I Wasnt Getting Errors This New Meter Version Seems To load Faster.
Glenn Please Delete All Old Meter Downloads I Have Here.
2010-06-08_074247_Meter4.zip
 
Gizmo

Admin Group

Joined: 05/06/2004
Location: Australia
Posts: 5078
Posted: 01:09am 08 Jun 2010
Copy link to clipboard 
Print this post

Yeah I've fixed a couple of the most annoying bugs, the corrupt serial data bug and incorrect com port bug, both which caused the PicLog to crash. I'll add Windmans version of the PicLog and source code later today.

Thanks for the Basic links Vasi, I have a few of the free ones now and will have a play when I get a few free hours.

Glenn
The best time to plant a tree was twenty years ago, the second best time is right now.
JAQ
 
Downwind

Guru

Joined: 09/09/2009
Location: Australia
Posts: 2333
Posted: 02:04am 08 Jun 2010
Copy link to clipboard 
Print this post

Windman,

The meters4 zip did load and run for me.
I also found it can be minimumised on the meters then stretched out to show all meters, and dragged to the bottom of the screen as a tool bar.
Much better than a large Green screen, but still takes up a lot of space.

I have only tested these and have not used them for any length of time in logging to know if they crash with time. As the earlier piclog was prone to do.

Pete.
Sometimes it just works
 
GWatPE

Senior Member

Joined: 01/09/2006
Location: Australia
Posts: 2127
Posted: 04:00pm 08 Jun 2010
Copy link to clipboard 
Print this post

Hi windman,

have finally had another chance to try and run the revised piclog programs.

I managed to start with the revised piclog from Gizmo.

I then copied the meter version to the same directory, that the working piclog was in. Once the calibrations had been set up, the meter version would run.... for a bit, before crashing with a runtime error 5. I also had the error 380 come up as well.

I think there may still be problems with data types within the program.

I hope you sort it so the meters that are displayed, reflect the options chosen in the setup as well.

Gordon.




become more energy aware
 
Gizmo

Admin Group

Joined: 05/06/2004
Location: Australia
Posts: 5078
Posted: 10:13pm 08 Jun 2010
Copy link to clipboard 
Print this post

Hey Gordon, are you using a original PicLog or a modified version that would be sending a different serial stream than normal? I ran Windmans version without any problems on a standard PicLog.

Also, the error codes dont help much, what we need to know is where within the program the error occured. If you have a copy of VB6, you can open Windmans source code and run the program from within VB6, instead of the compiled version. When the program crashes, VB6 will tell you exactly where and why, making it easy to fix the problem.

Glenn
The best time to plant a tree was twenty years ago, the second best time is right now.
JAQ
 
GWatPE

Senior Member

Joined: 01/09/2006
Location: Australia
Posts: 2127
Posted: 10:30pm 08 Jun 2010
Copy link to clipboard 
Print this post

Hi Glenn,

I have just run your code this morning, and you have introduced a timing bug. Even though the logging interval may have been changed, the logging interval stays at the previous timing. You need to go back into the prog setup again and exit for the change to be effective.

The changes you made to the comm routine is similar to my own, and I have not seen an error yet. I did have the comms hang with the update window frozen with all zero's for data. I had to press the calibrate button again. I don't close and reopen the comm port during the calibration, but leave the comms open and share the variables. The only time I close the comms, is during the port discovery routine, and upon program exit.

I don't have any source code for windmans program so I can't run it in the VB editor to check anything.

Gordon.




become more energy aware
 
vasi

Guru

Joined: 23/03/2007
Location: Romania
Posts: 1697
Posted: 11:42am 09 Jun 2010
Copy link to clipboard 
Print this post

  Gizmo said  Thanks for the Basic links Vasi, I have a few of the free ones now and will have a play when I get a few free hours.
Glenn


Welcome and please keep us updated about your evaluation/conclusions (maybe in another topic if you consider it is the case).

Vasi
Hobbit name: Togo Toadfoot of Frogmorton
Elvish name: Mablung Miriel
Beyound Arduino Lang
 
windman1000
Regular Member

Joined: 21/06/2009
Location: United States
Posts: 91
Posted: 09:15pm 09 Jun 2010
Copy link to clipboard 
Print this post

I have 2 new version 1 version is a better coding of the the set i posted here and the other version has 50 scale wind meters for the guys that do wind m/s.

I also figured out why the 380 error shows up, if your calibration setting are below or above The meter scales then you get the 380 error, ( example amp meter is scales for 100 so if you open the meter piclog and you are off scale say 101 amps or-1 amp you get the 380 error)
you can fix this by opening Glenns piclogger look at what readings you are getting and calibrate it there, or get the source code and change the scales.

any way here are the newer versions

2010-06-10_071525_wind_scale_50.zip

2010-06-10_071550_Wind_scale_100.zip
 
niall1

Senior Member

Joined: 20/11/2008
Location: Ireland
Posts: 331
Posted: 10:18pm 09 Jun 2010
Copy link to clipboard 
Print this post

hi Windman

i tried out your latest download version on 48v and it seems fine ..i need to let the
batts run down a little to watch the voltage readings but the pic seems to
be tracking the voltage well...

i,m running the pic cct off 12v from one battery , the sample 48v is tapped separately
the 39k resistor is changed to about 70k...this gives a reading of about 4v to the pic
pin at full battery voltage ....this is kind off suck it and see ...maybe i could change the clamp zener to 5v1 if a little extra headroom was needed...was wondering about that by what was discussed in previous posts ......



at the moment i,m just using the anemometer and battery v functions
very nice to see analogue meters as an option , there pretty easy on the eye

nice work to all concerned ....
niall
 
VK4AYQ
Guru

Joined: 02/12/2009
Location: Australia
Posts: 2539
Posted: 12:00am 10 Jun 2010
Copy link to clipboard 
Print this post

Hi All

You guys are doing a great job sorting this out, I like analogue gauges for scan checking and digital for logging accuracy so this is a great way to go. keep up the good work

All the best

Bob
Foolin Around
 
     Page 2 of 2    
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024