jl777
Legendary
Offline
Activity: 1176
Merit: 1134
|
 |
February 21, 2014, 12:50:18 PM |
|
CIYAM, I'm really amazed by your patience.
When you've traversed the depths of thousands of lines of code in order to find a bug that is as simple as an incorrect comma (and taken literally days to do so) then you will either have learned to be very patient with some things or you will have decided that computer programming is not for you. Here are the new structures. All amounts are in 'toshis, eg. satoshi, dogtoshi, NXTtoshi I generate the strings to send to bitcoind via %.8f and (double)longvalue/100000000 I am assuming this is safe, but wanted to be sure struct gateway_info { long balance,deposits,withdrawals,tbd __attribute__ ((packed)); int bind_requests,addresses_bound,deposit_txids,pending_sweeps,verified_deposits __attribute__ ((packed)); int withdrawal_requests,moneysent,pending_withdrawals,failed_withdrawals __attribute__ ((packed)); int rawbroadcasts,pending_redemptions __attribute__ ((packed)); };
struct gateway_AM { unsigned int sig __attribute__ ((packed)); int funcid __attribute__ ((packed)); int gatewayid __attribute__ ((packed)); int coinid __attribute__ ((packed)); long amount __attribute__ ((packed)); long unspent __attribute__ ((packed)); long change __attribute__ ((packed)); char NXTaddr[32],coinaddr[32]; union { char txid[128]; char rawtransaction[288]; }; union { char inputs[512]; }; struct gateway_info info; };
James
|
|
|
|
Zahlen
Member

Offline
Activity: 98
Merit: 10
|
 |
February 21, 2014, 12:53:44 PM |
|
CIYAM, I'm really amazed by your patience.
When you've traversed the depths of thousands of lines of code in order to find a bug that is as simple as an incorrect comma (and taken literally days to do so) then you will either have learned to be very patient with some things or you will have decided that computer programming is not for you. I would like to code stuff, but no thanks to C++ I lean towards the latter. Like, towards the end of every year when I'm free, I hunker down, write prototypes, then tear my hair in frustration. I'd really like a language that offers the low-level control and efficiency of C, the higher-level abstractions like objects, templates, inheritance and polymorphism of C++ (I could give up some things like virtual methods though), and the clean syntax of Python (imo, whitespace *should* be an integral part of syntax). I don't need cross-platform support, Windows is fine for now, I'm happy to port to specific platforms that I'm interested in. Does this language exist?
|
|
|
|
CIYAM
Legendary
Offline
Activity: 1890
Merit: 1126
Ian Knowles - CIYAM Lead Developer
|
 |
February 21, 2014, 12:55:52 PM |
|
@James - For displaying and other non-computational purposes temporarily using a "double" and "printf" is fine.
BTW - you would be better off using "long long" (or better yet #include <stdint.h> and use int64_t) than using "long" otherwise it won't work on most (if not all) 32 bit architectures.
|
|
|
|
xyzzyx
Sr. Member
  
Offline
Activity: 490
Merit: 250
I don't really come from outer space.
|
 |
February 21, 2014, 12:59:14 PM |
|
struct gateway_info { long balance,deposits,withdrawals,tbd __attribute__ ((packed)); ... };
struct gateway_AM { ... long amount __attribute__ ((packed)); long unspent __attribute__ ((packed)); long change __attribute__ ((packed)); ... };
You're using a 64-bit OS, I see.  long is only guaranteed to be a minimum of 32-bits in length and it's actual size is both OS and compiler dependent. The int64_t type is guaranteed to be at least 64-bits in length in any environment.
|
"An awful lot of code is being written ... in languages that aren't very good by people who don't know what they're doing." -- Barbara Liskov
|
|
|
CIYAM
Legendary
Offline
Activity: 1890
Merit: 1126
Ian Knowles - CIYAM Lead Developer
|
 |
February 21, 2014, 01:02:11 PM |
|
Does this language exist?
It is really hard to know which language is the best for what purpose (and in most typically non-trivial applications you'll end up using a few more than just one) but if you are keen to become a good programmer you should probably pick one "main" language and learn it "in depth". This process is not something that will happen "over night" but if you spend the effort you will have become a much better programmer (I spent over 10 years "learning" C++ whilst I worked with it and there are still areas of it that I am not familiar with).
|
|
|
|
|
rickyjames
|
 |
February 21, 2014, 01:03:57 PM Last edit: February 21, 2014, 08:45:52 PM by rickyjames |
|
NXT FUND SPENDING COMMITEE MEMBERSHIP SELECTION UPDATESince I'm the guy that slammed on the brakes back on page 1854 about no spending from the new NXT community funds until fund committees get organized, and since everybody generally seems to think that was an OK move, I feel the responsibility to try and get the ball rolling again on committee organization. Here we go. To organize a small group of people to spend big piles of money, there has to be a legitimate, transparent process to give them that power. The legitimate, transparent process we have gone through in this NXT community is that we have made the funding committee positions open to everyone. utopianfuture on Feb 2 started a funding committee nomination thread, almost three weeks ago: https://bitcointalk.org/index.php?topic=445209.0rickyjames on Feb 7-8 summarized the nominations made to that date in an identical post placed at four different forum locations: https://bitcointalk.org/index.php?topic=345619.msg5007861;topicseen#msg5007861https://bitcointalk.org/index.php?topic=445209.msg5007872#msg5007872https://nextcoin.org/index.php/topic,3890.msg36822.html#msg36822https://forums.nxtcrypto.org/viewtopic.php?f=2&t=753&p=3579&hilit=rickyjames#p3579Each of these posts ended with: *************************** NXT continues to develop at an incredible pace. If you've read this far, it's because you care about NXT. Consider applying for a committee seat to help take it further. NXT Community Nominations To The Funding Committee (NCNTTFC) thread : https://bitcointalk.org/index.php?topic=445209.0 *************************** The only further new nominations at all forum sites made as a result of these posts were: drevil was nominated for TechDev by gs02xzz hughmanwho and SecondLeo were nominated for the infrastructure committee by hughmanwho Come-from-Beyond on Feb 9 accepted Pouncer, klee and neer.g as treasurers of techdev, infrastructure and marketing funds respectively, and the 8,714,025 unclaimed NXT from the genesis block under his control was split equally among their assigned funds. Treasurers have NO authority to make spending decisions. Their role is to be a bank vault and only let money out when it is authorized by a "designated spending authority" - in this case, a SINGLE spokesperson from an elected committee, to be chosen by that committee once it is elected. https://bitcointalk.org/index.php?topic=445209.msg5032217#msg5032217https://bitcointalk.org/index.php?topic=445209.msg5040620#msg5040620Audit spreadsheets of NXT Fund assets are now permanently available , with the spreadsheet layout still being optimized at: https://docs.google.com/spreadsheet/ccc?key=0AoE8nAOEMIa7dFFnWjRNYTM4RkhsN3dRRXFBaTBiaHc#gid=14 , Pinarello on Feb 18 picked up efforts to elect spending committee members by opening a spreadsheet for expressions of interest by people actually willing to serve (instead of just being nominated by others): the post: https://bitcointalk.org/index.php?topic=445209.msg5220880#msg5220880the spreadsheet: https://docs.google.com/spreadsheet/ccc?key=0AsrKGhOkVcFpdFRFeHNUdWx3Qy1nTjBPLUFNWUJKQkE&usp=sharing#gid=0At the time of this writing, the only new names on this volunteer spreadsheet that have not been previously nominated as described above are: ^[GS]^, abuelau, Arckam (frmelin), bloodyrookie, Chanc3r, ChuckOne, CIYAM, Cointropolis_JustabitTime, Fry, Mario123, Pandaisftw, Ricot, TwinWinNerD, Zahlen, ZeroTheGreat Thus 55 nominees were picked after the three week nomination process described above, conducted over all three major NXT forum sites, allowing both self-nominations and nominations by others: ^[GS]^, 2Kool4Skewl, abuelau, Allwelder , Anon136, Arckam_(frmelin), bitcoinpaul, bloodyrookie, brooklynbtc, buybitcoinscanada, Chanc3r, ChuckOne, CIYAM, Cointropolis_JustabitTime, Come_from_Beyond, Damelon, Davetrouser, drevil, EmoneyRu, EvilDave, ferment, Fry, hughmanwho, Jean_Luc, jefdiesel, jl777, Joefox, Klee, l8orre, landomata, laowai80, Mario123, msin, mww, nexetrn, Nifty_Nickel, opticalcarrier, Pandaisftw, Passion_ltc, PeercoinEnthusiast, pinarello, Pouncer, rickyjames, Ricot, salsacz, SecondLeo, smaragda, TaiZen, TwinWinNerD, Uniqueorn, Utopianfuture, VanBreuk, Wesleyh, Zahlen, ZeroTheGreatBy the power vested in me from being full of hot air and having a big mouth, I hereby declare the period for accepting NXT Funding Committee nominations to be over.Anybody that has a problem with that, quote just the red line above and give it a -1. God help us if that happens. Since I've still got some hot air left and I still have a big mouth: We're gonna do a week of campaigning, and we're gonna have a one week long vote starting March 1.Anybody that has a problem with that, quote just the red line above and give it a -1. God help us if that happens. Campaigning is gonna work like this. I've opened up a new thread, NXT Funding Committee Nominee Statements: https://bitcointalk.org/index.php?topic=479167.new#newIf you are a nominee listed above, and you want to serve on ONE AND ONLY ONE of the NXTmarketingfund, NXTtechdevfund and NXTinfrastructure fund spending committees, go post your willingness to serve on this thread. State the committee you want to be on, and make a statement if you want about why you think you would be a good member for that committee. If you are not willing or able to make one single post on this thread, you probably aren't good committee material. Just sayin'. I will PM links to this post to all nominees at all sites and will repost it at the other two forums. I have set up polls on whether each committee should have 5 or 7 members. Go vote. https://bitcointalk.org/index.php?topic=479190.0https://bitcointalk.org/index.php?topic=479200.new#newhttps://bitcointalk.org/index.php?topic=479214.new#newI will set up three more polls for declared candidates on March 1 and repost everywhere calling for a vote for the agreed upon number of committee members for that committee. Yes, I'm being a dictator here. Sorry about that. At least I am a dictator with a suggestion box, speak up if you've got a problem or an idea. And I'm a dictator that's gonna step down on March 7, the day after I get back from representing NXT at Texas Bitcoin Conference. Because on March 7, there WILL be elected committees. (I hope).
|
|
|
|
|
jl777
Legendary
Offline
Activity: 1176
Merit: 1134
|
 |
February 21, 2014, 01:13:39 PM |
|
struct gateway_info { long balance,deposits,withdrawals,tbd __attribute__ ((packed)); ... };
struct gateway_AM { ... long amount __attribute__ ((packed)); long unspent __attribute__ ((packed)); long change __attribute__ ((packed)); ... };
You're using a 64-bit OS, I see.  long is only guaranteed to be a minimum of 32-bits in length and it's actual size is both OS and compiler dependent. The int64_t type is guaranteed to be at least 64-bits in length in any environment. fixed, though it has to be exactly 64 bits as it is being use to communicate to the gateway servers. It cant be more
|
|
|
|
pinarello
Full Member
 
Offline
Activity: 266
Merit: 100
NXT is the future
|
 |
February 21, 2014, 01:22:18 PM |
|
^[GS]^, 2Kool4Skewl, abuelau, Allwelder , Anon136, Arckam_(frmelin), bitcoinpaul, bloodyrookie, brooklynbtc, buybitcoinscanada, Chanc3r , ChuckOne, CIYAM, Cointropolis_JustabitTime, Come_from_Beyond, Damelon, Damelon, Davetrouser, drevil, EmoneyRu, EvilDave , ferment, Fry, hughmanwho, Jean_Luc, jefdiesel, jl777, Joefox, Klee, l8orre, landomata, laowai80, Mario123, msin, mww , nexetrn, Nifty_Nickel, opticalcarrier, Pandaisftw, Passion_ltc, PeercoinEnthusiast, pinarello, Pouncer, rickyjame, Ricot, salsacz, SecondLeo, smaragda, TaiZen, TwinWinNerD, Uniqueorn , Utopianfuture, VanBreuk, Wesleyh, Zahlen, ZeroTheGreat
thank you R I think there are people on the list that don"t want to be part of the committees, I hope they see it in time and let you know to delete them from the list. Also treasures should not be member of the committees imo
|
|
|
|
xyzzyx
Sr. Member
  
Offline
Activity: 490
Merit: 250
I don't really come from outer space.
|
 |
February 21, 2014, 01:25:16 PM |
|
long is only guaranteed to be a minimum of 32-bits in length and it's actual size is both OS and compiler dependent. The int64_t type is guaranteed to be at least 64-bits in length in any environment.
fixed, though it has to be exactly 64 bits as it is being use to communicate to the gateway servers. It cant be more I'm pretty sure the intX_t and uintX_t types are exact-width, but I don't have a reference near me at the moment to look it up (which is why I said int64_t was "at least" 64-bits above.) I can look this up later tonight to be sure if you need.
|
"An awful lot of code is being written ... in languages that aren't very good by people who don't know what they're doing." -- Barbara Liskov
|
|
|
jl777
Legendary
Offline
Activity: 1176
Merit: 1134
|
 |
February 21, 2014, 01:30:36 PM |
|
long is only guaranteed to be a minimum of 32-bits in length and it's actual size is both OS and compiler dependent. The int64_t type is guaranteed to be at least 64-bits in length in any environment.
fixed, though it has to be exactly 64 bits as it is being use to communicate to the gateway servers. It cant be more I'm pretty sure the intX_t and uintX_t types are exact-width, but I don't have a reference near me at the moment to look it up (which is why I said int64_t was "at least" 64-bits above.) I can look this up later tonight to be sure if you need. I am pretty sure it is exact. I just got concerned when you said at least. Got all money code converted to int64 so I am ready to start debugging actual deposit/withdraw process when I wake up. I am ashamed of the horrible parsing code, but I just want to get it working first, refactor later. Anyway, its almost noon after allnighter, gotta take a nap before debugging James
|
|
|
|
allwelder
Legendary
Offline
Activity: 1512
Merit: 1004
|
 |
February 21, 2014, 01:41:22 PM |
|
Hmm.. you are the second person to say this to me. I have no clue why. Anyone has any idea?  the same to me,I cannt post there too.
|
|
|
|
gimre
Legendary
Offline
Activity: 866
Merit: 1002
|
 |
February 21, 2014, 01:43:07 PM |
|
I would like to code stuff, but no thanks to C++ I lean towards the latter. Like, towards the end of every year when I'm free, I hunker down, write prototypes, then tear my hair in frustration.
I'd really like a language that offers the low-level control and efficiency of C, the higher-level abstractions like objects, templates, inheritance and polymorphism of C++ (I could give up some things like virtual methods though), and the clean syntax of Python (imo, whitespace *should* be an integral part of syntax). I don't need cross-platform support, Windows is fine for now, I'm happy to port to specific platforms that I'm interested in. Does this language exist?
D or Rust maybe?
|
|
|
|
gimre
Legendary
Offline
Activity: 866
Merit: 1002
|
 |
February 21, 2014, 01:44:19 PM |
|
CIYAM, I'm really amazed by your patience.
When you've traversed the depths of thousands of lines of code in order to find a bug that is as simple as an incorrect comma (and taken literally days to do so) then you will either have learned to be very patient with some things or you will have decided that computer programming is not for you. I have lot of patience when it comes to code and debugging... (as I know I'll eventually beat them) I can't say I have that much patience when it comes to arguing with people...
|
|
|
|
CIYAM
Legendary
Offline
Activity: 1890
Merit: 1126
Ian Knowles - CIYAM Lead Developer
|
 |
February 21, 2014, 01:49:49 PM |
|
I'm pretty sure the intX_t and uintX_t types are exact-width, but I don't have a reference near me at the moment to look it up (which is why I said int64_t was "at least" 64-bits above.) I can look this up later tonight to be sure if you need.
They are *exactly* the number of bits their names suggest (that's why they were created). It is the normal C types like "int" and "long" which the Standard can only give vague ideas about size (such as sizeof( long ) >= sizeof( int ), etc.).
|
|
|
|
CIYAM
Legendary
Offline
Activity: 1890
Merit: 1126
Ian Knowles - CIYAM Lead Developer
|
 |
February 21, 2014, 01:52:22 PM |
|
I have lot of patience when it comes to code and debugging... (as I know I'll eventually beat them) I can't say I have that much patience when it comes to arguing with people...
I'd have to say that I am the same - so I prefer not to "argue" with people but instead try "discuss" with them (it doesn't always work mind you especially in a forum like this one). Provided that it doesn't turn into an argument then I can remain quite patient (if it starts to head that way I would normally "move on").
|
|
|
|
|
rickyjames
|
 |
February 21, 2014, 01:52:55 PM Last edit: February 21, 2014, 07:33:16 PM by rickyjames |
|
Also treasures should not be member of the committees imo
Sigh. For the record, there's a difference between being a "treasurer" and being a "designated spending authority". James / jl777 is the sole " designated spending authority" for NXTcommunityfund and NXTcashfunds, which are run by him as an individual with no committee structure. He is like Santa Claus and the Tooth Fairy all rolled up into one, he can give those funds out as he sees fit to anybody he feels is helping NXT. He gets to do this because NXTcommunityfund and NXTcashfunds are private funds set up by neer.g and Pouncer as a private deal with James. Anybody contributing to these funds (and contributions are encouraged!) does so with the understanding that James is the ultimate designated spending authority from the original private deal that set up these funds. I am a treasurer of NXTcommunityfund and NXTcashfunds. I have the password to those funds and nobody else does. I COULD spend this NXT, but I have NO authority to do so. I only spend exactly what James tells me to do exactly as he says, no more, no less. Public access to the blockchain and audit spreadsheets is the check and balance on ME and how the community keeps me honest. Now, James can't just spend these funds on HIMSELF with no oversight. If James designates funds to be sent to HIM instead of SOMEBODY ELSE, then I have to clear it with neer.g or Pouncer first. That is the check and balance on this huge power James has. He doesn't have the password to the money, and somebody else has to give him permission to spend it on his own projects. So, a "treasurer" has no real power except the power of trust and honesty. They exist only as a check-and-balance against the "designated spending authority" going nuts and running off with all the NXT. And the first thing an elected fund committee is going to have to do is decide which ONE of their members is going to be the "designated spending authority" that signs the orders that goes to the treasurers. Now, I'm going to run for a seat on the infrastructure committee because I am a hardware guy, not a coder, and setting up a worldwide network to support NXT at 1000 TPS looks like a really interesting challenge to me. I am going to run for this position even tho I am a treasurer on other funds. I don't think there's a problem with that. If that bothers people after reading the explanation above, then they can vote against me and I won't get in. And I'll accept that if it happens. We'll see.
|
|
|
|
|
|
Mario123
|
 |
February 21, 2014, 01:54:32 PM |
|
Just got this e-mail back from MintPal after informing them that Nxt should not be Nextcoin. Hi Mario, It is actually called Nextcoin from what I can see https://nextcoin.org/Thanks though. Regards, Jay MintPal 
|
|
|
|
Zahlen
Member

Offline
Activity: 98
Merit: 10
|
 |
February 21, 2014, 01:56:36 PM |
|
By the power vested in me by being full of hot air and having a big mouth, I hereby declare the period for accepting NXT Funding Committee nominations to be over.
Anybody that has a problem with that, quote just the red line above and give it a -1. God help us if that happens.
...
And I'm a dictator that's gonna step down on March 7, the day after I get back from representing NXT at Texas Bitcoin Conference. Because on that day, there WILL be elected committees. (I hope).
+1. No gods, no kings, no temporary big-mouthed hot air always young at heart benevolent dictators, only committees Nxters. Hi Mario, It is actually called Nextcoin from what I can see https://nextcoin.org/Thanks though. Regards, Jay MintPal God help us all.
|
|
|
|
abctc
Legendary
Offline
Activity: 1820
Merit: 1040
|
 |
February 21, 2014, 01:59:03 PM |
|
Just got this e-mail back from MintPal after informing them that Nxt should not be Nextcoin. Hi Mario, It is actually called Nextcoin from what I can see https://nextcoin.org/Thanks though. Regards, Jay MintPal - thanks to ...
|
██████████████████████████████████████████████████ ████████████████████████████████████████████████████ ██████████████████████████████████████████████████████ ████████████████████████████████████████████████████████ ████████████████████████████████████████████████████████ ████████████████████████████████████████████████████████████████████ ████████████████████████████████████████████████████████████ ██████████████████████████████████████████████████████████████ ████████████████████████████████████████████████████████████████ ██████████████████████████████████████████████████████████████████ ████████████████████████████████████████████████████████████████████ | , the Next platform. Magis quam Moneta (More than a Coin) |
|
|
|
|
apenzl
|
 |
February 21, 2014, 01:59:48 PM |
|
Just got this e-mail back from MintPal after informing them that Nxt should not be Nextcoin. Hi Mario, It is actually called Nextcoin from what I can see https://nextcoin.org/Thanks though. Regards, Jay MintPal  Wonderful… @ allwelder >
|
|
|
|
|