Programming Editor Wishlist

pleiser

Senior Member
A helpful feature would be the ability to compare the changes in the code since the last save (perhaps even last several versions), sort of like the app "kaleidoscope" on the mac app store.

P.S. any news on P.E. 6 progress?
 

nick12ab

Senior Member
A helpful feature would be the ability to compare the changes in the code since the last save (perhaps even last several versions), sort of like the app "kaleidoscope" on the mac app store.
Excellent idea.

Until then, you could download some third party software like WinMerge which is free - no "Half price only $34.99"!

winmerge.png

Or you can use the fc command line command but it isn't as nice.
fc /C /L D:\file1.bas D:\file2.bas produces: (only put the first bit because it's quite long)
Code:
Comparing files D:\file1.bas and D:\FILE2.BAS
***** D:\file1.bas
0(w0) | Bits          |  loopcounter  | moving average|               |               | moving average|
1(w0) |               |  readvar      | 1       w10   | autolevel2    | autolevel22   | 11  w25       |
2(w1) |               | bintoascii1/T | moving average| autolevel3    | autolevel23   | moving average|
***** D:\FILE2.BAS
0(w0) | Bits          |  loopcounter  | moving average|               |               | moving average|
1(w0) |               |               | 1       w10   | autolevel2    | autolevel22   | 11  w25       |
2(w1) |               | bintoascii1/T | moving average| autolevel3    | autolevel23   | moving average|
*****

***** D:\file1.bas
6(w3) |  count1 w3    | bintoascii5   | moving average| autolevel7    | autolevel27   |---------------|
7(w3) |  count1       | pwmdutyvar    | 4       w13   |               |               |
8(w4) |  count2 w4    | moving average| level1        | moving average| moving average|
***** D:\FILE2.BAS
6(w3) |  count1 w3    | bintoascii5   | moving average| autolevel7    | autolevel27   |---------------|
7(w3) |  count1       | pwmdutyvar    | 4       w13   | skew1         | skew2         |
8(w4) |  count2 w4    | moving average| level1        | moving average| moving average|
*****

***** D:\file1.bas
 2 | bits          | autolevel3    | autolevel23   |               |               |               |
 3 |               | autolevel4    | autolevel24   |               |               |               |
 4 |               | autolevel5    | autolevel25   |               |               |               |
 5 |               | autolevel6    | autolevel26   |               |               |               |
***** D:\FILE2.BAS
 2 | bits          | autolevel3    | autolevel23   |               |               |               |
 3 | skew1         | autolevel4    | autolevel24   |               |               |               |
 4 | skew2         | autolevel5    | autolevel25   |               |               |               |
 5 |               | autolevel6    | autolevel26   |               |               |               |
*****

***** D:\file1.bas
symbol loopcounter      = b10
symbol readvar          = b11
symbol bta1                     = b12
***** D:\FILE2.BAS
symbol loopcounter      = b10
symbol bta1                     = b12
*****

***** D:\file1.bas
symbol autolevel7               = b36

symbol autolevel22      = b41
***** D:\FILE2.BAS
symbol autolevel7               = b36
symbol skew1            = b37
symbol autolevel22      = b41
*****

***** D:\file1.bas
symbol autolevel27      = b46
symbol s1                       = 4
***** D:\FILE2.BAS
symbol autolevel27      = b46
symbol skew2            = b47
symbol s1                       = 4
*****

***** D:\file1.bas
        138,146,156,169,189,226)
        adcsetup = 16
        adcsetup2 = 4
        high fan1
        high fan2
        read 0,level1
        read 1,level2
        read 2,b0
        read 11,autolevel2
        read 12,autolevel3
        read 13,autolevel4
        read 14,autolevel5
        read 15,autolevel6
        read 16,autolevel7
        read 21,autolevel22
        read 22,autolevel23;
        read 23,autolevel24
        read 24,autolevel25
        read 25,autolevel26
        read 26,autolevel27
        b0 = b0 and $03
        setfreq em64
        dirsB = 255
        low rs
        output enable
        lcddata = %00000110 : pulsout enable,100
        lcddata = %00001100 : pulsout enable,100
        lcddata = %00111011 : pulsout enable,100
        lcddata = %00000001 : pulsout enable,100
        pause 100
        low rs
        lcddata = 64 : pulsout enable,1
        high rs
        for loopcounter = 0 to 55
                lookup loopcounter,(32,32,32,32,32,32,63,32,32,32,32,32,32,63,63,32,32,32,32,32,63,63,63,32,32,32,32,63,_
                                          63,63,63,32,32,32,63,63,63,63,63,32,32,63,63,63,63,63,63,32,63,63,63,63,63,63,63,32),
readvar
                lcddata = readvar
                pulsout enable,1
***** D:\FILE2.BAS
        138,146,156,169,189,226)
        adcsetup = 16                                                                           'Configure ADC inputs
        adcsetup2 = 4                                                                           'Configure ADC inputs
        high fan1                                                                                       'Turn fan 1 on - done i
n case fan cannot start on lowest PWM setting
        high fan2                                                                                       'Turn fan 2 on - done i
n case fan cannot start on lowest PWM setting
        read 0,level1                                                                           'Read set speed level for fan 1

        read 1,level2                                                                           'Read set speed level for fan 2

        read 2,b0                                                                                       'Read saved bit variabl
es
        read 3,skew1
        read 4,skew2
        read 11,autolevel2                                                                      '
        read 12,autolevel3                                                                      'Fan 1
        read 13,autolevel4                                                                      'auto levels
        read 14,autolevel5                                                                      '
        read 15,autolevel6                                                                      '
        read 16,autolevel7                                                                      '
        read 21,autolevel22                                                                     '
        read 22,autolevel23                                                                     'Fan 2
        read 23,autolevel24                                                                     'auto levels
        read 24,autolevel25                                                                     '
        read 25,autolevel26                                                                     '
        read 26,autolevel27                                                                     '
        b0 = b0 and $03                                                                         'Keep only first two bits of b0

        setfreq em64                                                                            'Use 16MHz resonator
        dirsB = 255                                                                                     'Set pinsB as outputs
        low rs                                                                                  'instruction mode
        output enable                                                                           'set enable pin as output
        lcddata = %00000110 : pulsout enable,100                                                'OLED initialization
        lcddata = %00001100 : pulsout enable,100                                                'OLED initialization
        lcddata = %00111011 : pulsout enable,100                                                'OLED initialization
        lcddata = %00000001 : pulsout enable,100                                                'OLED initialization
        pause 100                                                                                       'Allow OLED to finish i
nitialization
        lcddata = 64 : pulsout enable,1                                                 'Set selected OLED RAM location to 64 f
or loading CGRAM characters
        high rs                                                                                 'Data mode
        for loopcounter = 0 to 63                                                               'Loop: Load CGRAM characters fo
r level meter
                lookup loopcounter,(32,32,32,32,32,32,63,32,32,32,32,32,32,63,63,32,32,32,32,32,63,63,63,32,32,32,32,63,_
                                          63,63,63,32,32,32,63,63,63,63,63,32,32,63,63,63,63,63,63,32,63,63,63,63,63,63,63,32,_

                                          63,63,63,63,63,63,63,63),lcddata
                pulsout enable,1
*****
 

Paix

Senior Member
A helpful feature would be the ability to compare the changes in the code since the last save (perhaps even last several versions), sort of like the app "kaleidoscope" on the mac app store.
Sort of like the *nix diff command . . .
 

nerdegutta

Senior Member
I haven't read all 33 pages so this might have been mentioned before.

A way to capture the 0-255 EEPROM "table" to a file or screen while using the debug. Or a clear way of showing how to do this.

A feature to implement ASM or C code.

A few more general variables, b0-b40.

-nerdegutta
 
Last edited:

westaust55

Moderator
Some PICAXE chips have 28 byte variables (some older ones have less) and others have 56 byte variables (b0 to b55) as detailed in the PICAXE manual 2 under general variables.
There are also means to save and retrieve values in the byte variables to other RAM using PEEK and POKE or into scratchpad memory with PUT and GET.
Some of these techniques have been discussed on this forum previously.

PICAXE chips use BASIC and tokenise/interpret the program.
C+ is a completely different t language although typically what is written in C can be translated to BASIC if one has the skills.

Allowing assembler code blocks will likely never be imimented on PICAXE.
Anyone could then write code to read and dump the proprietary PICAXE firmware with interprets the BASIC command. Then unscrupulous types clone the PICAXE so Revolution Education's profits fall and the demise of Rev Ed and PICAXE chips may follow.
 

nerdegutta

Senior Member
Some PICAXE chips have 28 byte variables (some older ones have less) and others have 56 byte variables (b0 to b55) as detailed in the PICAXE manual 2 under general variables.
There are also means to save and retrieve values in the byte variables to other RAM using PEEK and POKE or into scratchpad memory with PUT and GET.
Some of these techniques have been discussed on this forum previously.
Unfortunately, I don't have those IC's at hand.

Allowing assembler code blocks will likely never be imimented on PICAXE.
Anyone could then write code to read and dump the proprietary PICAXE firmware with interprets the BASIC command. Then unscrupulous types clone the PICAXE so Revolution Education's profits fall and the demise of Rev Ed and PICAXE chips may follow.
Ah... I see only the good in people, so that didn't occur to me. :)

How about the EEPROM? Is there a way to display it while using debug? Like it is when you are simulating?


- nerdegutta
 

Technical

Technical Support
Staff member
The EEPROM contents are not part of the debug packet, so no.

However you could do this

#terminal 4800
for b1 = 0 to 255
read b1,b2
sertxd ("address=",#b1, "data=",#b2,cr,lf )
next b1
 

f2cf1g

Member
I know this is the interpreter really, but I would like a variant on serout with another parameter to specify an inter-character transmission delay.
 

oracacle

Senior Member
the ability to drag pain out of the window, ie one PE open with one program in a pain on another screen while working on another program in the PE window
 

inglewoodpete

Senior Member
I know this is the interpreter really, but I would like a variant on serout with another parameter to specify an inter-character transmission delay.
Code:
b0 = 0: b1 = 0
Do Until b1 = 255
   Lookup b0, ("Hello World", 255), b1
   Serout C.3, (b1)
   Inc b0
Loop
End
 

westaust55

Moderator
A helpful feature would be the ability to compare the changes in the code since the last save (perhaps even last several versions)
There is a free online utility to perform this task:
http://www.comparemyfiles.com/default.aspx

Attached as an example of the output is a collage image of the output using a piece of code recently posted by IWP and a modified version.
 

Attachments

pleiser

Senior Member
Another function that would be useful would be a variant of terminal that emulates axe033, 133 ect serial LCDs. This could be used to see if a problem was in hardware or software, or start programming before adding the LCD/OLED.

~patrick

EDIT: 333rd post :) !
 
Last edited:

inglewoodpete

Senior Member
Another function that would be useful would be a variant of terminal that emulates axe033, 133 ect serial LCDs. This could be used to see if a problem was in hardware or software, or start programming before adding the LCD/OLED.
I'll second that idea. Good thinking.
 

Buzby

Senior Member
Make the PWMOUT wizard 'copy to PE' function add an inline comment showing what the result is :

Code:
pwmout 2, 199, 400	' Set PWM on pin 2 to 10Khz 50% duty, at 8MHz clock
... and make the wizard stay open while you try out different settings on the target PICAXE.
 

TheChief

Senior Member
A helpful feature would be the ability to compare the changes in the code since the last save (perhaps even last several versions)
You could create your own cvs on your local computer using open source software such as Subversion or GIT.
This will allow you to compare and rollback to different versions.
Just remember to commit your work after each save you make in your editor. You could automate this process by looking at file system changes but that's another story.

In short I agree and hope that support would be directly added in the future. :p
 

Buzby

Senior Member
A button to turn all TAB characters into a matching number of SPACE characters.

( I'm fed up with re-jigging code after inserting into forum posts, or printing through my oh-so-clever Windows drivers. )
 

nick12ab

Senior Member
Is PE6 nearly ready now?

I've noticed that this post from Technical has colour syntax!
Use bptr to point to the position you want, you can't use array type notation e.g. (0) in symbol names.

Code:
[COLOR=Blue]symbol [/COLOR][COLOR=Black]fault1 [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Purple]b1[/COLOR]
[COLOR=Blue]symbol [/COLOR][COLOR=Black]fault2 [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Purple]b2[/COLOR]
[COLOR=Blue]symbol [/COLOR][COLOR=Black]fault3 [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Purple]b3[/COLOR]
[COLOR=Blue]symbol [/COLOR][COLOR=Black]fault4 [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Purple]b4[/COLOR]
[COLOR=Blue]symbol [/COLOR][COLOR=Black]fault5 [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Purple]b5[/COLOR]

[COLOR=Blue]for [/COLOR][COLOR=Purple]bptr [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Navy]1 [/COLOR][COLOR=Blue]to [/COLOR][COLOR=Navy]5 [/COLOR][COLOR=Green];Loop for DTCs 1-5
      [/COLOR][COLOR=Blue]let [/COLOR][COLOR=Purple]b0 [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Navy]1 [/COLOR][COLOR=Green];Set b0(fault) to 1
      [/COLOR][COLOR=Blue]pulsin [/COLOR][COLOR=Black]pulse,[/COLOR][COLOR=Navy]0[/COLOR][COLOR=Black],[/COLOR][COLOR=Purple]w13 [/COLOR][COLOR=Green];Measure low pulses & store @ w13
      [/COLOR][COLOR=Blue]if [/COLOR][COLOR=Purple]w13 [/COLOR][COLOR=DarkCyan]> [/COLOR][COLOR=Navy]400 [/COLOR][COLOR=Blue]then[/COLOR][COLOR=Green];If low pulse is greater than 400, gosub faultcount
            [/COLOR][COLOR=Blue]let [/COLOR][COLOR=Black]temp [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Navy]0 [/COLOR][COLOR=Green];Set temp to 0
            [/COLOR][COLOR=Blue]gosub [/COLOR][COLOR=Black]faultcount [/COLOR][COLOR=Green];Goto sub routine to count pulses
      [/COLOR][COLOR=Blue]endif [/COLOR][COLOR=Green];End IF statement

      [/COLOR][COLOR=Purple]@bptr [/COLOR][COLOR=DarkCyan]= [/COLOR][COLOR=Black]temp [/COLOR][COLOR=Green];Assign temp value to fault(b0)
      [/COLOR][COLOR=Blue]inc [/COLOR][COLOR=Black]temp [/COLOR][COLOR=Green];Increment bo(fault)[/COLOR]
[COLOR=Blue]next   [/COLOR][COLOR=Green];Increment loop[/COLOR]
[COLOR=Blue]goto [/COLOR][COLOR=Black]results [/COLOR][COLOR=Green];Loops finished, goto results[/COLOR]
 

AllyCat

Senior Member
I've noticed that this post from Technical has colour syntax!
Hi,

But hasn't PE 5.5.5 (and maybe a few versions before that) already got colour syntax?

And whilst I'm here, another vote to be able to edit (or at least scroll and read) the program when the terminal window is open!

Cheers, Alan.
 

Buzby

Senior Member
Hi,

But hasn't PE 5.5.5 (and maybe a few versions before that) already got colour syntax?

Cheers, Alan.
The current PE has colour syntax, but the 'Copy to Forum' function doesn't transfer the colours when pasted.

So I think the post from nick is hinting that PE 6 must include coloured 'Copy to Forum'.

Anyway, I've given up whinging about the non-appearance of anything more than what we've got now. Waited too long,
 

Armp

Senior Member
I just hope they add an option to print in fixed font, and maintain formatting.

And yes I've tried printing to pdf and all the other tricks.
 

pleiser

Senior Member
The ability to only program certain microcontroller (selected in program) would be useful, eg. in my laptop project I have two picaxe 28X2s, one for main processor, one for keyboard monitering, I oftem accidentaly program the wrong one (with the other's program) and wonder why it dosen't work. so it would be useful to restrict the program to only program one chip (perhaps defined in previous versions of program).
 
It may have been mentioned in this l-o-n-g thread already but....

1. Implied logic for desicion statements (actually raised by hwholmes in another thread)
If b0 Then....
If Not pin C.1 Then...
Do While pinC.1....
I would like to see an additional logic-related capability:
Code:
bit1 = b2 > b3
where bit1 would be set to 0 if b2 was NOT greater than b3, and set to 1 if b2 was greater than b3.
 

Hemi345

Senior Member
Hi,

And whilst I'm here, another vote to be able to edit (or at least scroll and read) the program when the terminal window is open!

Cheers, Alan.
Another vote for this. Actually, it would be nice if we could edit/scroll/read the program when any of the other windows are open. For example, if the ASCII table (in the Help menu) is open, I can't edit my program and view the table at the same time.

One other thing, and I'm just nitpicking, but remove the close window X on the download dialog box. It doesn't do anything and always teases me into clicking it when I realize I haven't plugged in the download cable. ;)
 

nick12ab

Senior Member
More of a PICAXE Manual/website wish actually...

Regularly people post on the forum asking how to specify the value placed in the variable by commands including readadc10, readtemp and pulsin and the answer is to use the Generic thingy which only gets a brief mention in PICAXE Manual 1. So I think that it might be a good idea to specify on the PICAXE BASIC Commands page for the individual command plus in PICAXE Manual 2 for each command (e.g. readadc10) that uses the Generic thingy in the simulator that you have to use the Generic thingy.
 

pleiser

Senior Member
Commands could automatically compensate for set frequency e.g chip is set to 16 MHz, 2cfast becomes i2cfast_16, pauses double etc. the adjustments could be compiler (or interpreter, or whatever) side only, maybe defined by #frequency.
 
Last edited:

inglewoodpete

Senior Member
Commands could automatically compensate for set frequency e.g chip is set to 16 MHz, 2cfast becomes i2cfast_16, pauses double etc. the adjustments could be compiler (or interpreter, or whatever) side only, maybe defined by #frequency.
I've thought about that one too but the speed of the PICAXE is dynamic: the user can change it at any time for a number of reasons. Eg Slowing the PICAXE in some parts of your program to conserve battery power or when using a longer than standard i2c bus. Also, you sometimes need to drop the speed to get some slower baud rates. Therefore, the compiler could never be smart enough to know what division rate to use. Rev-Ed could do it in the chips themselves but that would need a rewrite of the firmware!
 

pleiser

Senior Member
I've thought about that one too but the speed of the PICAXE is dynamic: the user can change it at any time for a number of reasons. Eg Slowing the PICAXE in some parts of your program to conserve battery power or when using a longer than standard i2c bus. Also, you sometimes need to drop the speed to get some slower baud rates. Therefore, the compiler could never be smart enough to know what division rate to use. Rev-Ed could do it in the chips themselves but that would need a rewrite of the firmware!
True, but perhaps it could be an option that you would only use if your program was all the same frequency, or you could specify one chunk of code (which would always be the same frequency) to apply it to (sort of like #rem followed by #endrem).

P.S.
The release of PE6
I agree!
 

pleiser

Senior Member
Extended ASCII support, Ideally matching the characters used in the AXE134 OLEDs and LCDs.

EDIT:
...but remove the close window X on the download dialog box. It doesn't do anything and always teases me into clicking it when I realize I haven't plugged in the download cable.
or better yet, make the X work.
 

Buzby

Senior Member
Today is the 500th Anniversary since PE6 was first dangled before our eyes.

I think we all deserve a slice of the cake !.
 

SAborn

Senior Member
Today is the 500th Anniversary since PE6 was first dangled before our eyes.

I think we all deserve a slice of the cake !.
Perhaps Re-ed has already blowen the candles out on PE6.
 
Top