Longmove in spin
Anyone can explain me a little why the longmove(@cs, @cspin, 4) is used and how that relates to the pins that get assigned at the start.
I set my pins too 15, 12, 14, 13
isn't it easier to just write directly to a pin?
long cs ' chip select
long clk ' clock
long mosi ' master out slave it (to MCP3208)
long miso ' master in slave out (from MCP3208)
pub start(cspin, clkpin, mosipin, misopin)
longmove(@cs, @cspin, 4) ' copy pins
outa[cs] := 1 ' output high (disable)
dira[cs] := 1
outa[clk] := 0 ' output low
dira[clk] := 1