Writing a Payment context requires PHP knowledge.

Create and configure a Payment

You will have to create a Payment object and set a description, currency code, finish callback and line items, among other things. If you want to be sure a Payment is correctly configured, also create a payment method that uses a PaymentMethodBasicController payment method controller and call PaymentMethod::validate() on the payment. Doing this does not mean your payment can be processed by all payment methods that exist, because some of them may not support the currency you're using, for instance. This is simply a limitation of those payment methods and Payment will automatically detect this for you.
Calling Payment::execute() will execute the payment in its current configuration. See the payment execution workflow for what happens next.

Create and display a payment form (optional)

Most contexts will want to display a payment form to have payers select a payment method and optionally configure it (like choosing Credit card as the method and the specific card type as the configuration). This is, however, not required, as this configuration can also be set programmatically.

To create a payment form, it's easiest to create your own custom form and use payment_form_embedded() directly to get the core payment form elements, or to display payment_form_standalone() by calling drupal_get_form('payment_form_standalone'), which calls payment_form_embedded() for you.

As you probably guessed payment_form_embedded() is the core of any payment form. It comes with hook_payment_form_alter(), which should be used to alter the form rather than hook_form_alter() or hook_form_FORM_ID_alter(), because those two are not invoked when using payment_form_embedded() directly.