AXE-033 Serial LCD problem

free1000

New Member
I'm trying to connect the serial LCD in to my application, but I'm not seeing the correct characters output.

According to the project PDF for the Serial LCD and Clock, which I'm using as a guide to using this component, incorrect characters may be output and the fix is in Appendix A, internal resonator tuning. I cant see a way to simulate this in the Picaxe VSM software as it refers to connecting RST pads.

I don't think I'm going wrong. Is this a bug in the beta?
 

Attachments

Last edited:

Technical

Technical Support
Staff member
The AXE033 model is a beta version we are still working on. At present it only supports T2400 (not N2400) formatted data, and does not support the clock functions yet. Look at the AXE110 datalogger example for an example.
 

free1000

New Member
The AXE033 model is a beta version we are still working on. At present it only supports T2400 (not N2400) formatted data, and does not support the clock functions yet. Look at the AXE110 datalogger example for an example.
Thanks for this, I can see the display working in the AXE110 example...

T commands work fine in my application. Thanks!

This is a great bit of software.

Cheers
 
Last edited:

ArnieW

Senior Member
The AXE033 model is a beta version we are still working on. At present it only supports T2400 (not N2400) formatted data, and does not support the clock functions yet. Look at the AXE110 datalogger example for an example.
I've been spending too much time on this one and still not getting results which I suspect is due to the modelling. What happens is that I get odd characters appearing on screen.

For example, I have a subroutine like this:

Code:
    serout oLCD, T2400, (254,128)
    if SWmode=1 then
        serout oLCD, T2400, ("L")    'show 'L'
    else
        serout oLCD, T2400, ("l")    'show 'l'
    endif
It works the first time ok, but the second time through puts a character on screen that looks like a space invader, then a space (in response to the first line - the positioning command). It then prints the right character 'l' as per code.

Any ideas?

thanks, Arnie

PS. VSM is fabulous, I love it.
 

ArnieW

Senior Member
Please can you post your whole BASIC program with this new problem.
Hi Technical, what follows is a shortened/modified version that still produces strange output on the LCD.

Code:
#picaxe 40x


init:

    'inputs     
    symbol TempA=1    ;DS18B20 temperature
    symbol TempB=2    ;DS18B20 temperature

    'outputs
    symbol oLCD=2    'LCD display

    'variables
    symbol SWmodeA=b0    
    symbol SWmodeB=b1    
    symbol SWmodeC=b2    
    symbol HtrPwr=b3
    symbol wTraw=w2    ;raw temperature data from DS18B20
    symbol act_T=w2    ;actual temperature in * 10 degrees
    
    'insert test values
    SWmodeA=0
    SWmodeB=1
    SWmodeC=1
    HtrPwr=50

    'power up LCD
    pause 1000

    'initialise LCD screen
    serout oLCD, T2400, (254,128)        'line 0 posn 0
    if SWmodeA=1 then
        serout oLCD, T2400, ("L")    'show 'L'
    else
        serout oLCD, T2400, ("l")    'show 'l'
    endif

    serout oLCD, T2400, (254, 135)
    if SWmodeB=1 then
        serout oLCD, T2400, ("C")    'show 'C'
    else
        serout oLCD, T2400, ("c")    'show 'c'
    endif
    
    serout oLCD, T2400, (254, 192, "M")    'show 'M'

    serout oLCD, T2400, (254, 199)
    if SWmodeC=1 then
        serout oLCD, T2400, ("K")    'show 'K'
    else
        serout oLCD, T2400, ("k")    'show 'k'
    endif

    serout oLCD, T2400, (254, 205)    
    if HtrPwr < 10 then
        serout oLCD, T2400, ("  ", #HtrPwr)    
    elseif HtrPwr < 100 then
        serout oLCD, T2400, (" ", #HtrPwr)    
    else
        serout oLCD, T2400, (#HtrPwr)    
    endif

    serout oLCD, T2400, ("%")    

    
main:

    ReadTemp12 TempA,wTraw    ;12 bit resolution read of DS18B20 probe
    ;temp = raw * 0.0625
    ;to display temp in 1 decimal place * 10 (ie. integer):
    ;temp = raw * 0.625
    ;temp = raw * 5/8
    act_T= wTraw * 5/8    ;raw temp now in *10 format
    'move to correct screen position
    serout oLCD, T2400, (254, 193)    
    'and display it
    gosub subWriteLCDtempUnits
    gosub subWriteLCDtempDec
    
    ReadTemp12 TempB,wTraw    ;12 bit resolution read of DS18B20 probe
    ;temp = raw * 0.0625
    ;to display temp in 1 decimal place * 10 (ie. integer):
    ;temp = raw * 0.625
    ;temp = raw * 5/8
    act_T= wTraw * 5/8    ;raw temp now in *10 format
    act_T= act_T        ;calibrate temp
    'move to correct screen position
    serout oLCD, T2400, (254, 136)    
    'and display it
    gosub subWriteLCDtempUnits
    gosub subWriteLCDtempDec

    goto main
    
subWriteLCDtempUnits:
    
    act_T=act_T/10    'degrees value (units)
    if act_T<10 then
        serout oLCD, T2400, ("0", #act_T)
    elseif act_T<100 then
        serout oLCD, T2400, (#act_T)
    else
        serout oLCD, T2400, (254, 16, #act_T)
    endif
    return
        
subWriteLCDtempDec:

    act_T=act_T//10    'degrees value (tenths)
    serout oLCD, T2400, (".", #act_T)
    return
thanks
 
Top