HX512K and XMM
blittled
Posts: 681
I recently got a HX512K SRAM for my Hydra and was wondering if I could use XMM with it? I realize the first 64K will be fast and the remaining memory will be slower because of how it steps through memory.
Comments
Someone needs to write a Propeller-GCC cache driver for it.
this is what I had some time ago:
* "hydrahx0.spin" is meant to support full 512KB with original firmware, using "page walk" instead of "byte walk" after the first 64KB.
Clearly this is not quite true "random access", but I think that using the cache it does not much worst than other serial mediums (I2C EEPROMs, or single bit SPI SRAMs).
Earlier I ran speed tests using this method (not with gcc code code, just reading and writing, 4096 times, 256 byte memory pages, located randomly in the 512KB address space).
The results were some 5 times slower vs the enhanced firmware, where with the original firmware + original "byte walk" method, it would be more than 20 times slower.
* "hydrahx1.spin" is probably the most interesting, for Hydra and HX512 with Eric Moyer's firmware.
* "protohx2.spin" (unfinished), is supposed to work with HX512 attached to a protoboard and a 74hc74 chip to speed things up (maybe).
All three are untested, I was unable to test them on GEAR back then, IIRC because I had difficulties loading XMM from serial port.
Hope you guys can find some use for this.
Alessandro
Quite correct. The HX512 uses Propeller pin P30 as a clock strobe, essentially disabling normal serial communications on P30/P31. From the HX512 manual:
... once the HYDRA boots and the USB_RXD line is quiet then if its clocked by any COG other than the one communicating with the HX512 then you run the risk of instructing the HX512 to load addresses, read or write which would be unintentional.This is a side-effect since the USB_RXD line doubles for the SRAM_CLK line on the HX512 which is more or less the “execute command” strobe line. Thus, the HX512 when inserted disallows the serial communications from the PC for all intent purposes. This has nothing to do with programming of course, this issue only comes into play after the programming of the EEPROM or Propeller is complete by the Propeller tool.
As David mentioned, Catalina and Payload support a special Hydra_Mouse loader - once this loader is loaded via normal means (with the HS512 essentially quiescent - or at least in a state we don;t care about - it then supports programs being loaded to the HX512 via another port, such as a serial mouse or keyboard port. Payload allows multiple programs to be specified for successive loading, so it takes care of this automatically if you give it a command such as:
Ross.