SpinAsm AND and Using the FV1Dev on Microsoft Windows: Difference between pages

From PedalPCB Wiki
(Difference between pages)
Jump to navigation Jump to search
 
(Created page with "This method has been tested on Microsoft Windows 10. Other versions may be compatible but have not been verified. ''All links to software downloads are provided for convenience only. PedalPCB provides no guarantee about the fit or function of third party software.'' == Download FV1Dev Bundle for Windows == http://wiki.pedalpcb.com/files/FV1Dev-Windows.zip FV1Dev Bundle for Windows == Configure AsProgrammer to Read / Write 24LC32A EEPROMs == Choose PedalPCB /...")
 
Line 1: Line 1:
==AND==
This method has been tested on Microsoft Windows 10.  Other versions may be compatible but have not been verified.
{| class="wikitable"
|+
!Mnemonic
!Operation
!Instruction coding
|-
|AND
|ACC & MASK
|MMMMMMMMMMMMMMMMMMMMMMMM000001110
|}


======Description======
''All links to software downloads are provided for convenience only.  PedalPCB provides no guarantee about the fit or function of third party software.''
AND will perform a bit wise "and" of the current ACC and the 24­bit MASK specified within the instruction word. The instruction might be used to load a constant into ACC provided ACC contains $FFFFFF or to clear ACC if MASK equals $000000. (see also the pseudo opcode section)
{| class="wikitable"
|+
!Name
!Width
!Entry formats, range
|-
|M
|24 Bit
|Binary
Hex ($000000 - $FFFFFF)
Symbolic
|}


======Syntax======
== Download FV1Dev Bundle for Windows ==
AND M


======Coding Example======
[[http://wiki.pedalpcb.com/files/FV1Dev-Windows.zip FV1Dev Bundle for Windows]]
<syntaxhighlight line="1">
 
AMASK EQU $F0FFFF                  ;
== Configure AsProgrammer to Read / Write 24LC32A EEPROMs ==
                                    ;
 
;------------------------------------
Choose PedalPCB / _FV1 / _24LC32A from the IC menu in AsProgrammer
or $FFFFFF                          ; Set all bits within ACC
 
and  $FFFFFE                        ; Clear LSB
[[File:Asprogrammer-selectdevice.png|AsProgrammer screenshot|alt=AsProgrammer screenshot]]
and  %01111111_11111111_11111111    ; Clear MSB
 
and  AMASK                          ; Clear ACC[19..16]
== Reading and Writing EEPROMs ==
and  $0                            ; Clear ACC
 
</syntaxhighlight>
=== Read EEPROM ===
1) Choose the 24LC23A device from the IC menu (see above)
 
2) Click the green "Read IC" button to read data from EEPROM
 
3) Click the "Save file" icon to save the data to a file
 
=== Write EEPROM ===
 
1) Choose the 24LC23A device from the IC menu (see above)
 
2) Click the "Open file" icon, choose the file you want to write (must be in .BIN format, see below for conversion)
 
3) Click the "Program IC" icon to write data to the EEPROM.  All data currently on EEPROM will be lost!
 
== File Formats ==
 
AsProgrammer reads and writes EEPROM data as .BIN binary files. SpinAsm and SpinCAD export files in Intel HEX format, so the file will need to be converted before writing to EEPROM.
 
Conversion is possible using the included SRecord executable.
 
=== Convert Intel HEX to BIN ===
<code>
srec_cat.exe <filename.hex> -Intel -o <filename.bin> -binary
</code>
 
=== Convert BIN to Intel HEX ===
<code>
srec_cat.exe <filename.bin> -binary -o <filename.hex> -Intel
</code>

Revision as of 20:30, 6 January 2023

This method has been tested on Microsoft Windows 10. Other versions may be compatible but have not been verified.

All links to software downloads are provided for convenience only. PedalPCB provides no guarantee about the fit or function of third party software.

Download FV1Dev Bundle for Windows

[FV1Dev Bundle for Windows]

Configure AsProgrammer to Read / Write 24LC32A EEPROMs

Choose PedalPCB / _FV1 / _24LC32A from the IC menu in AsProgrammer

AsProgrammer screenshot

Reading and Writing EEPROMs

Read EEPROM

1) Choose the 24LC23A device from the IC menu (see above)

2) Click the green "Read IC" button to read data from EEPROM

3) Click the "Save file" icon to save the data to a file

Write EEPROM

1) Choose the 24LC23A device from the IC menu (see above)

2) Click the "Open file" icon, choose the file you want to write (must be in .BIN format, see below for conversion)

3) Click the "Program IC" icon to write data to the EEPROM. All data currently on EEPROM will be lost!

File Formats

AsProgrammer reads and writes EEPROM data as .BIN binary files. SpinAsm and SpinCAD export files in Intel HEX format, so the file will need to be converted before writing to EEPROM.

Conversion is possible using the included SRecord executable.

Convert Intel HEX to BIN

srec_cat.exe <filename.hex> -Intel -o <filename.bin> -binary

Convert BIN to Intel HEX

srec_cat.exe <filename.bin> -binary -o <filename.hex> -Intel